package test5;

import java.io.FileOutputStream;
import java.io.FileWriter;
import java.io.IOException;
import java.io.ObjectOutputStream;

public class Test {
    public static void main(String[] args) throws IOException {
        Student stu = new Student("迪丽热巴","女",18);

        ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream("stream-test\\test5_1.txt"));
        oos.writeObject(stu);

        oos.close();
    }
}
